/*
 * @Author: Simon 1958058172@qq.com
 * @Date: 2025-08-19 14:54:29
 * @LastEditors: Simon 1958058172@qq.com
 * @LastEditTime: 2025-08-19 15:04:22
 * @FilePath: \java.1212\csdn\xiancheng\li03\Test.java
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
package csdn.xiancheng.li03;

public class Test {
    public static void main(String[] args) {
        Thread t1=new Thread(){
            @Override
            public void run() {
                super.run();

            }
        };
        //获取线程状态 NEW
        System.out.println(t1.getState());
        System.out.println(t1.getState());
        t1.start();
        //状态：RUNNABLE
        System.out.println(t1.getState());
        System.out.println(t1.getState());
        
        try {
            t1.sleep(100);
        } catch (InterruptedException e) {
            e.printStackTrace();
        }
        //主线程休眠
        System.out.println(t1.getState());
        System.out.println(t1.getState());
    }
}
